const InitialState = {
  channels: [],
  page: 1,
  pageSize: 10,
  list: [],
  count: 0,
}
export const article = (state = InitialState, action) => {
  if (action.type === 'article/getChannels') {
    return {
      ...state,
      channels: action.payload,
    }
  }

  if (action.type === 'article/getArticles') {
    return {
      ...state,
      ...action.payload,
    }
  }
  return state
}
